package co.yixiang.modules.shop.web.vo;

import cn.hutool.core.util.StrUtil;
import co.yixiang.modules.shop.entity.YxStoreProductAttrValue;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Date;
import java.util.List;

/**
 * <p>
 * 商品表 查询结果对象
 * </p>
 *
 * @author hupeng
 * @date 2019-10-19
 */
@Data
@ApiModel(value = "YxStoreProductQueryVo对象", description = "商品表查询参数")
public class YxStoreProductQueryVo implements Serializable {
    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "商品id")
    private Integer id;

    @ApiModelProperty(value = "商户Id(0为总后台管理员创建,不为0的时候是商户后台创建)")
    private Integer merId;

    @ApiModelProperty(value = "商品图片")
    private String image;

    private String image_base;

    private String codeBase;

    public String getImage_base() {
        return image;
    }

    private Boolean userCollect = false;

    private Boolean userLike = false;

    @ApiModelProperty(value = "轮播图")
    private String sliderImage;

    private List<String> sliderImageArr;

    public List<String> getSliderImageArr() {
        //Arrays.asList(sliderImage.split(","));
        if (StrUtil.isNotEmpty(sliderImage)) {
            return Arrays.asList(sliderImage.split(","));
        }

        return new ArrayList<>();

    }

    private YxStoreProductAttrValue attrInfo;

    @ApiModelProperty(value = "商品名称")
    private String storeName;

    @ApiModelProperty(value = "商品简介")
    private String storeInfo;

    @ApiModelProperty(value = "关键字")
    private String keyword;

    @ApiModelProperty(value = "产品条码（一维码）")
    private String barCode;

    @ApiModelProperty(value = "分类id")
    private String cateId;

    @ApiModelProperty(value = "商品价格")
    private BigDecimal price;

    @ApiModelProperty(value = "会员价格")
    private BigDecimal vipPrice;

    @ApiModelProperty(value = "市场价")
    private BigDecimal otPrice;

    @ApiModelProperty(value = "邮费")
    private BigDecimal postage;

    @ApiModelProperty(value = "单位名")
    private String unitName;

    @ApiModelProperty(value = "排序")
    private Integer sort;

    @ApiModelProperty(value = "线上总销量")
    private Integer sales;

    @ApiModelProperty(value = "线下总销量")
    private Integer storeSales;

    @ApiModelProperty(value = "库存")
    private Integer stock;

    @ApiModelProperty(value = "状态（0：未上架，1：上架）")
    private Integer isShow;

    @ApiModelProperty(value = "是否热卖")
    private Integer isHot;

    @ApiModelProperty(value = "是否优惠")
    private Integer isBenefit;

    @ApiModelProperty(value = "是否精品")
    private Integer isBest;

    @ApiModelProperty(value = "是否新品")
    private Integer isNew;

    @ApiModelProperty(value = "产品描述")
    private String description;

    @ApiModelProperty(value = "添加时间")
    private Integer addTime;

    @ApiModelProperty(value = "是否包邮")
    private Integer isPostage;

    @ApiModelProperty(value = "是否删除")
    private Integer isDel;

    @ApiModelProperty(value = "商户是否代理 0不可代理1可代理")
    private Integer merUse;

    @ApiModelProperty(value = "获得积分")
    private BigDecimal giveIntegral;

    @ApiModelProperty(value = "成本价")
    private BigDecimal cost;

    @ApiModelProperty(value = "秒杀状态 0 未开启 1已开启")
    private Integer isSeckill;

    @ApiModelProperty(value = "砍价状态 0未开启 1开启")
    private Integer isBargain;

    @ApiModelProperty(value = "是否优品推荐")
    private Integer isGood;

    @ApiModelProperty(value = "虚拟销量")
    private Integer ficti;

    @ApiModelProperty(value = "浏览量")
    private Integer browse;

    @ApiModelProperty(value = "产品二维码地址(用户小程序海报)")
    private String codePath;

    @ApiModelProperty(value = "淘宝京东1688类型")
    private String soureLink;

    @ApiModelProperty(value = "是否是投资选品库  0:否 1:是")
    private Integer isStockInvest;

    @ApiModelProperty(value = "数据来源 0:手工添加  1:外部商品库")
    private Integer dataSource;

    @ApiModelProperty(value = "产地")
    private String place;

    @ApiModelProperty(value = "是否被投资  0:否  1:是")
    private Integer isInvested;

    @ApiModelProperty(value = "投资成本价")
    private BigDecimal investCost;

    @ApiModelProperty(value = "投资价")
    private BigDecimal investPrice;

    @ApiModelProperty(value = "销量参考")
    private String salesReference;

    @ApiModelProperty(value = "促销价")
    private BigDecimal promotePrice;

    @ApiModelProperty(value = "保留状态   0:未保留    1:已保留")
    private Integer lockStatus;
    @ApiModelProperty(value = "保留释放时间 单位:秒")
    private Integer lockReleaseTime;
    @ApiModelProperty(value = "保留释放时间(以时间为单位)")
    private Date lockReleaseDateTime;
    @ApiModelProperty(value = "保留时间")
    private Date lockTime;
    @ApiModelProperty(value = "保留人")
    private String locker;
    @ApiModelProperty(value = "保留类型    1: 手工保留   2:认购保留   3:支付保留")
    private Integer lockType;
    @ApiModelProperty(value = "保留人id")
    private Integer lockerId;
    @ApiModelProperty(value = "品牌")
    private String brandName;
    @ApiModelProperty(value = "仓库存量")
    private String warehouseStock;
    @ApiModelProperty(value = "门店id")
    private String storeId;
    @ApiModelProperty(value = "门店名称")
    private String storePname;

    @ApiModelProperty(value = "是否上架投资端     0: 否   1:是")
    private Integer isInvestOn;

    @ApiModelProperty(value = "品牌ID")
    private Integer brandId;

    @ApiModelProperty(value = "产地id")
    private Integer placeId;

    @ApiModelProperty(value = "添加人")
    private String adder;

    @ApiModelProperty(value = "促销开始时间")
    private Date promoteBeginTime;

    @ApiModelProperty(value = "促销结束时间")
    private Date promoteEndTime;

    @ApiModelProperty(value = "成本价")
    private BigDecimal purchasePrice;

    @ApiModelProperty(value = "区域评分")
    private Integer areaScore;

    @ApiModelProperty(value = "季节评分")
    private Integer seasonScore;

    @ApiModelProperty(value = "偏好评分")
    private Integer likeScore;

    @ApiModelProperty(value = "品牌评分")
    private Integer brandScore;

    @ApiModelProperty(value = "平台评分")
    private Integer platformScore;

    @ApiModelProperty(value = "风险评分")
    private Integer riskScore;

    @ApiModelProperty(value = "综合评分")
    private Integer compositeScore;

    @ApiModelProperty(value = "认购建议")
    private String investSuggest;

    @ApiModelProperty(value = "起订量")
    private String miniQuantity;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "规格")
    private String suk;

}